
.text-variant {
  font-variant: small-caps;
}

.dataTables_paginate .page-link {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  line-height: 1.5;
}

.dataTables_paginate .page-item:first-child .page-link {
  border-top-left-radius: 0.2rem;
  border-bottom-left-radius: 0.2rem;
}

.dataTables_paginate .page-item:last-child .page-link {
  border-top-right-radius: 0.2rem;
  border-bottom-right-radius: 0.2rem;
}

.data-table td a:not(.btn), .data-table td a:hover:not(.btn) {
  display: block;
  text-decoration: none;
  color: inherit;
}

.data-table th {
  white-space: nowrap;
}

.data-table td {
  white-space: nowrap;
  padding-top: 1px;
  padding-bottom: 1px;
}

.data-table td.testcase-results {
  white-space: normal;
  word-wrap: break-word;
}

.dataTables_filter {
  text-align: inherit;
}

.table-wrapper {
  display: inline-block;
}

.force-width a {
  max-width: 20em;
  text-overflow: ellipsis;
  overflow: hidden;
}

#notification-box {
  position: fixed;
  z-index: 1075;
  right: 0;
  bottom: 0;
}

.editormd-fullscreen {
  z-index: 1200;
}

body {
  color: black;
  background-color: white;
  font-family: Roboto, Arial, Helvetica, sans-serif;
  padding-bottom: 4em;
  padding-top: 4rem;
}

.cursor-pointer {
  cursor: pointer;
}

@media (min-width: 768px) {
  body {
    padding-top: 4.5rem;
  }
}

/* menu */
#menuDefault ul li.nav-item {
  white-space: nowrap;
}

#djlogo {
  width: 93px;
  height: 196px;
}

.submitform {
  max-width: 450px;
}

.clarificationform {
  max-width: 800px;
}

.disabled {
  color: silver !important;
}

.unseen {
  font-weight: bold;
}

.data-table .ignore, table td.ignore {
  text-decoration: line-through;
}

.probid, .langid { font-variant: small-caps; }

.verdict-sm, .badge-testcase {
  width: 20px;
  margin-right: 1px;
}

.sol {
  font-weight: bold;
  font-variant: small-caps;
}

@keyframes spinner-border {
  to {
    transform: rotate(360deg);
  }
}

.spinner-border {
  display: inline-block;
  width: 2rem;
  height: 2rem;
  vertical-align: text-bottom;
  border: 0.25em solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spinner-border .75s linear infinite;
}

.spinner-border-sm {
  width: 1rem;
  height: 1rem;
  border-width: 0.2em;
}

@keyframes spinner-grow {
  0% {
    transform: scale(0);
  }
  50% {
    opacity: 1;
  }
}

.spinner-grow {
  display: inline-block;
  width: 2rem;
  height: 2rem;
  vertical-align: text-bottom;
  background-color: currentColor;
  border-radius: 50%;
  opacity: 0;
  animation: spinner-grow .75s linear infinite;
}

.spinner-grow-sm {
  width: 1rem;
  height: 1rem;
}

.sol_correct      { color: green;  }
.sol_incorrect    { color: red;    }
.sol_queued       { color: gray;   }

.judgetime      { font-size: smaller; font-style: italic; }
.testcases_prev { font-size: xx-small; }
.prevsubmit     { color: #696969; }

.output_text {
  border-top: 1px dotted #C0C0C0;
  border-bottom: 1px dotted #C0C0C0;
  background-color: #FAFAFA;
  margin: 0;
  padding: 5px;
  font-family: Consolas, monospace;
  white-space: pre;
}

.teamid { font-family: Consolas, monospace; }
.filename, .hostname { font-family: Consolas, monospace; }

.nodata {
  color: gray;
  font-style: italic;
}

a.collapse-link { color: black; text-decoration: none; }

table.lcsdiff {
  border-spacing: 0;
  border-collapse: collapse;
}

table.lcsdiff td.linenr {
  background-color: darkgray;
  text-align: right;
  border-right: solid 1px black;
  padding-right: 7px;
}

ins {
  background: #dfd;
  text-decoration: none;
}

del {
  background: #fdd;
  text-decoration: none;
}

.run h4 {
  font-size: 1.25rem;
  padding-top: 1rem;
}

.run h5 {
  font-size: 0.9rem;
  font-weight: bold;
  padding-top: 1.2rem;
}

.source-tab {
  border-bottom: 1px solid #dee2e6;
  border-right: 1px solid #dee2e6;
  border-left: 1px solid #dee2e6;
  padding: 0.5rem;
}

#lastmod {
  position: absolute;
  right: 1ex;
  margin-top: 1em;
}

#lastmod, #lastmod a {
  font-size: x-small;
  color: gray;
  text-align: right;
}

.center { margin: 0px auto; }

.scoreboard {
  border-collapse: collapse;
  clear: both;
}

.scoreboard td {
  font-size: small;
  vertical-align: middle;
  text-align: center;
}

.scoreboard td div {
  width: 4em;
  font-size: 120%;
  display: inline-block;
}

.scoreboard td div span {
  font-weight: normal;
  font-size: 70%;
  display: block;
}

.scoreboard tr {
  border-bottom: 1px solid black;
  height: 42px;
}

.scoreboard td, .scoreboard th {
  border-right: 1px solid silver;
  padding: 0px;
}

.scoreboard td.score_cell {
  min-width: 4.2em;
  border-right: none;
}

.scoreboard a {
  display: block;
  padding: 2px 1px 2px 1px;
  text-decoration: none;
  color: black;
}

.scoreboard .scoretn {
  padding: 0px 5px 0px;
  text-align: right;
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.forceWidth {
  min-width: 6rem;
  max-width: 13rem;
  text-overflow: ellipsis;
  position: relative;
  display: block;
  overflow: hidden;
}

.toolong:after {
  content: "";
  width: 30%;
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
}

.scoreboard .scoreaf { white-space: nowrap; border: 0; text-align: center; }
.scoreboard .scoreaf img { vertical-align: middle; }

.univ {
  font-size: 80%;
  font-weight: normal;
  color: dimgrey;
}

img.affiliation-logo {
  height: 32px;
  width: 32px;
}

.scoreboard tr.scoreheader {
  font-variant: small-caps;
  border-bottom: 2px solid black;
  white-space: nowrap;
}

.scoreheader th {
  text-align: center;
}

.problempoints {
  font-size: smaller;
  font-weight: normal;
  color: #303030;
  padding-left: 3pt;
  padding-right: 3pt;
}

.gym_correct     { color: #0a0; font-weight: bold; }
.gym_incorrect   { color: #00a; }
.score_correct   { background: #60e760; }
.score_first     { background: #1daa1d !important; }
.score_pending   { background: #6666FF; }
.score_incorrect { background: #e87272; }

#scoresolv,#scoretotal { width: 2.5em; }
.scorenc,.scorett,.scorepl { text-align: center; width: 2ex; }
.scorenc { font-weight: bold; }
td.scorenc { border-color: silver; border-right: 0; }

.scoreprob { width: 3.0em; vertical-align: middle; }
.scoreaffil { text-align: center; }

#scoresummary {
  border-top: 2px solid black;
  border-bottom: none;
  font-variant: small-caps;
}

.scorethisisme  {
  background: #ffff99;
}

.scorelegend {
  display: inline-block;
  vertical-align: top;
}

.scorelegend td, .scorelegend th {
  text-align: center;
  width: 25ex;
}

#teamscoresummary { margin-top: 2.5em; }

/* between different sortorder-categories, print a thick line */
.sortorderswitch { border-top: 2px solid black; }

.circle {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid black;
  display: inline-block;
}

.heart {
  padding: .3em;
  cursor: pointer;
}

.countryflag {
  height: 30px;
  width: 40px;
}

table.rejudgetable td {
  text-align: center;
}

table.rejudgetable td.changed {
  background-color: #fdd;
  font-weight: bold;
}

table.rejudgetable td.identical {
  background-color: #dfd;
}

table.rejudgetable td.zero {
  background-color: #F0F8FF;
}

tr.ignore td, td.ignore, span.ignore {
  text-decoration: line-through;
}

.clarification-subject-form, .clarification-queue-form {
  display: none;
}

.form-inline {
  display: inline;
}

.input-group-text {
  font-size: small;
  width: 3em;
}

.card-header .fa {
  transition: .5s transform ease-in-out;
}
.card-header .collapsed .fa {
  transform: rotate(90deg);
}

.upload-progress {
  width: 100%;
  height: 10px;
  background: #ccc;
  border-radius: 10px;
  overflow: hidden;
}

.upload-progress > div {
  width: 0px;
  height: 100%;
  background-color: dodgerblue;
  transition: all .3s ease;
}

.banner {
  width: 98%;
  height: auto;
  display: block;
  margin: -3rem auto 3rem auto;
}

#teampicture {
  width: 100%;
  border: 1px solid black;
}

.problem-list h3, .problem-list h4, .problem-list h5 {
  text-align: center;
}

.problem-list h3 {
  font-size: 1.17em;
}

.problem-list h4 {
  font-size: 1.12em
}

.problem-list h5 {
  font-size: .83em;
}

#teamwelcome {
  padding-top: 3rem;
}

#teamwelcometeam {
  font-weight: bold;
}

#contestnotstarted {
  color: silver;
  margin-top: .2ex;
  font-weight: normal;
}

h3.teamoverview {
  border-top: solid 1px darkgray;
  border-bottom: solid 1px darkgray;
  background-color: #c4d8ff;
  margin-top: 2ex;
  padding-left: 1ex;
  font-size: 1.17em;
  text-align: center;
}

.ajax-loader-container {
  height: 40px;
}

.ajax-loader {
  top: 8px;
  right: 10px;
  margin-left: 10px;
  position: relative;
}

.navbar-dark .ajax-loader {
  color: rgba(255, 255, 255, 0.5);
}

.navbar-light .ajax-loader {
  color: rgba(0, 0, 0, .5);
}

.scrollable-menu {
  height: auto;
  max-height: 500px;
  overflow-x: hidden;
}

.error-template {
  padding: 40px 15px;
  text-align: center;
}


/* Rating system */

a.rank-show,
a.rank-show:hover {
  text-decoration: none;
  font-weight: 600;
}

.rank-unrated {
  color: black !important;
  font-weight: 400 !important;
}

.rank-newbie {
  color: gray !important;
}

.rank-expert {
  color: blue !important;
}

.rank-pupil {
  color: green !important;
}

.rank-specialist {
  color: #03A89E !important;
}

.rank-candidate-master {
  color: #a0a !important;
}

.rank-master,
.rank-international-master {
  color: #FF8C00 !important;
}

.rank-grandmaster,
.rank-legendary-grandmaster,
.rank-international-grandmaster {
  color: red !important;
}

.rank-legendary-grandmaster:first-letter {
  color: black !important;
}

@media (min-width: 1600px) {
  .container {
    max-width: 1540px;
  }
}

/* .samp */
.samp .input, .samp .output {
  border: 1px solid #888888;
}

.samp .output {
  margin-bottom: 1em;
  position: relative;
  top: -1px;
}

.samp .output pre, .samp .input pre {
  background-color: #EFEFEF;
  line-height: 1.25em;
  margin: 0;
  padding: 0.25em;
}

.samp .title {
  background-color: #FFFFFF;
  border-bottom: 1px solid #888888;
  font-family: arial;
  font-weight: bold;
  padding: 0.25em;
}

.input-output-copier {
  font-size: 0.8rem;
  float: right;
  color: #888 !important;
  cursor: pointer;
  border: 1px solid rgb(185, 185, 185);
  padding: 3px;
  margin: 1px;
  line-height: 0.9rem;
  text-transform: none;
}

.input-output-copier:hover {
  background-color: #def;
}

.btn-text {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  display: inline;
}

/* Navbar underline */

@media (max-width: 991.98px) {
  .offcanvas-collapse {
    position: fixed;
    top: 56px; /* Height of navbar */
    bottom: 0;
    left: 100%;
    width: 100%;
    padding-right: 1rem;
    padding-left: 1rem;
    overflow-y: auto;
    visibility: hidden;
    background-color: #343a40;
    transition: visibility .3s ease-in-out, -webkit-transform .3s ease-in-out;
    transition: transform .3s ease-in-out, visibility .3s ease-in-out;
    transition: transform .3s ease-in-out, visibility .3s ease-in-out, -webkit-transform .3s ease-in-out;
  }
  .offcanvas-collapse.open {
    visibility: visible;
    -webkit-transform: translateX(-100%);
    transform: translateX(-100%);
  }
}

.nav-scroller {
  position: relative;
  z-index: 2;
  height: 2.75rem;
  overflow-y: hidden;
}

.nav-scroller .nav {
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: nowrap;
  flex-wrap: nowrap;
  padding-bottom: 1rem;
  overflow-x: auto;
  color: rgba(255, 255, 255, .75);
  text-align: center;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
}

.nav-underline .nav-link {
  padding-top: .75rem;
  padding-bottom: .75rem;
  font-size: .875rem;
  color: #6c757d;
}

.nav-underline .nav-link:hover {
  color: #007bff;
}

.nav-underline .active {
  font-weight: 500;
  color: #343a40;
}

/* Theme controlling */

.window-card {
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  border-width: 0px;
  padding-left: 0;
  padding-right: 0;
  border-radius: 0;
}

.window-card > .card-body {
  padding: 0 0 0.5rem;
}

.window-card > .card-body .panel-bottom {
  text-align: right;
  margin-top: 1.5em;
}

.card-pagination > .card-body {
  padding-bottom: 0;
  padding-top: 0;
}

.card-pagination > .card-body > ul.pagination {
  margin-bottom: 0;
}

.h2-more {
  float: right;
  font-size: 1rem;
}

.card-head {
  background-color: #f2f2f2;
  margin-left: -15px;
  margin-right: -15px;
}

.card-fill {
  margin-top: 0;
  margin-bottom: 2rem;
}

.card-head ~ .card-body {
  padding: 1.5rem 0 1.5rem;
}

.card-table > table > thead {
  display: none;
}

.card-table > table > tbody > tr:hover,
.card-table > table > tbody > a:hover {
  background-color: rgba(0,0,0,.03);
  text-decoration: none;
}

.card-table tr th,
.card-table a th {
  color: #737373;
  font-weight: 400;
}

.card-table table thead > a[role="row"],
.card-table table tbody > a[role="row"] {
  display: table-row;
  color: inherit;
}

.card-table thead > tr > th {
  border: 0;
}

@media (min-width: 576px) {

  body.body-card-theme {
    background-color: #f7f8f9;
  }

  .card-table > table > thead {
    display: table-header-group;
  }

  .card-fill {
    margin-top: 3rem;
    margin-bottom: 4rem;
  }

  .card-head {
    border-top-left-radius: 0.23rem !important;
    border-top-right-radius: 0.23rem !important;
    margin-left: 0;
    margin-right: 0;
  }

  .window-card {
    border-width: 1px;
    margin-top: 3rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
    border-radius: 0.25rem !important;
  }

  .card-container > .window-card {
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
  }

  .window-card > .card-body {
    padding: 2rem 1.5rem 1.5rem;
  }

  .card-head ~ .card-body {
    padding: 2rem;
  }

  .card-table {
    margin-left: -1.5rem;
    margin-right: -1.5rem;
    margin-bottom: -1.5rem;
  }

  .card-table tr td:first-child,
  .card-table tr th:first-child,
  .card-table a td:first-child,
  .card-table a th:first-child {
    padding-left: 1.65rem;
  }

  .card-table tr td:last-child,
  .card-table tr th:last-child,
  .card-table a td:last-child,
  .card-table a th:last-child {
    padding-right: 1.65rem;
  }

  .card-pagination > .card-body {
    padding: 0.6rem 0.5rem;
  }

  .card-pagination .pagination > .page-item:first-child > .page-link,
  .card-pagination .pagination > .page-item:last-child > .page-link {
    border-radius: 1.125rem;
  }

  .card-pagination .page-link {
    border-color: rgba(0,0,0,.125);
    border-radius: 1.125rem;
    border: none;
    height: 2.25rem;
    width: 2.25rem;
    line-height: 1.7rem;
    font-size: 0.9rem;
    text-align: center;
    margin-left: 0.1rem;
    margin-right: 0.1rem;
  }

  .card-container > .alert.alert-primary {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 64, 133, 0.075) !important;
  }

  .card-container > .alert.alert-secondary {
    box-shadow: 0 0.125rem 0.25rem rgba(56, 61, 65, 0.125) !important;
  }

  .card-container > .alert.alert-success {
    box-shadow: 0 0.125rem 0.25rem rgba(21, 87, 36, 0.125) !important;
  }

  .card-container > .alert.alert-info {
    box-shadow: 0 0.125rem 0.25rem rgba(12, 84, 96, 0.125) !important;
  }

  .card-container > .alert.alert-warning {
    box-shadow: 0 0.125rem 0.25rem rgba(133, 100, 4, 0.125) !important;
  }

  .card-container > .alert.alert-danger {
    box-shadow: 0 0.125rem 0.25rem rgba(114, 28, 36, 0.125) !important;
  }

  .card-container > .alert.alert-light {
    box-shadow: 0 0.125rem 0.25rem rgba(129, 129, 130, 0.125) !important;
  }

  .card-container > .alert.alert-dark {
    box-shadow: 0 0.125rem 0.25rem rgba(27, 30, 33, 0.125) !important;
  }
}

body.body-compact-theme {
  padding-bottom: 0;
  padding-top: 3.5rem
}

@media all and (min-width:768px) {
  body.body-compact-theme {
    padding-top: 3.5rem
  }
}
